const install = (Vue, vm) => {
	let userCode2Session = (params = {}) => vm.$u.get('/api/user/code2Session', params); //小程序授权
	let qyCode2SessionSmall = (params = {}) => vm.$u.get('/api/user/qyCode2SessionSmall', params); //企业小程序授权
	let userLogin = (params = {}) => vm.$u.post('/api/user/login', params); //登录
	let qyLogin = (params = {}) => vm.$u.post('/api/user/qyLogin', params); //企业微信登录
	let bidFindAll = (params = {}) => vm.$u.get('/api/bid/findAll', params); //获取全部标段
	let siteFindAll = (params = {}) => vm.$u.get('/api/site/findAll', params); //获取全部工地
	let departmentFindAll = (params = {}) => vm.$u.get('/api/department/findAll', params); //获取全部部门/专业/岗位/工种
	let laborerFindAll = (params = {}) => vm.$u.get('/api/laborer/findAll', params); //获取全部劳务公司
	let userFindList = (params = {}) => vm.$u.get('/api/user/findList', params); //分页获取用户
	let userFind = (params = {}) => vm.$u.get('/api/user/find', params); //获取用户详情
	let reasonFindAll = (params = {}) => vm.$u.get('/api/reason/findAll', params); //获取全部审核原因
	let userAudit = (params = {}) => vm.$u.post('/api/user/audit', params); //审核
	let fileUpdate = (params = {}) => vm.$u.post('/api/file/upload', params); //上传图片
	let userVerify = (params = {}) => vm.$u.post('/api/user/verify', params); //身份验证
	let userAdd = (params = {}) => vm.$u.post('/api/user/add', params); //用户认证
	let userOcrBankCard = (params = {}) => vm.$u.post('/api/user/ocrBankCard', params); //银行卡OCR识别
	let findByUserBidAll = (params = {}) => vm.$u.get('/api/bid/findByUserBidAll', params); //根据用户Id获取标段
	let userFindByAuditUsers = (params = {}) => vm.$u.get('/api/user/findByAuditUsers', params); //获取未审核的用户
	let signUserContract = (params = {}) => vm.$u.post('/api/user/signUserContract', params); //签署劳动合同
	let signUserNotification = (params = {}) => vm.$u.post('/api/user/signUserNotification', params); //签署进场告知书
	let findByUserIdContract = (params = {}) => vm.$u.get('/api/record/findByUserIdContract',
		params); //获取劳务人员用工合同
	let findByUserIdNotification = (params = {}) => vm.$u.get('/api/record/findByUserIdNotification',
		params); //获取劳务人员进场告知书

	vm.$u.api = {
		userCode2Session,
		qyCode2SessionSmall,
		userLogin,
		qyLogin,
		bidFindAll,
		siteFindAll,
		departmentFindAll,
		userFindList,
		userFind,
		userAudit,
		fileUpdate,
		userVerify,
		userAdd,
		laborerFindAll,
		reasonFindAll,
		userOcrBankCard,
		findByUserBidAll,
		userFindByAuditUsers,
		signUserContract,
		signUserNotification,
		findByUserIdContract,
		findByUserIdNotification
	};
}

export default {
	install
}
